package com.qf.dao;

import com.qf.pojo.Category;
import com.qf.pojo.User;

import java.sql.SQLException;
import java.util.List;

/**
 * @author Mr.Liu
 * @date 2021/11/19 10:32
 */

public interface UserDao {


    /**
     * 查找所有用户数据访问接口层
     * */
    List<User> findAllUser() throws SQLException;
    /**
     * 通过id查找用户数据访问接口层
     * */
    User selectById(String uid) throws SQLException;
    /**
     * 修改用户数据访问接口层
     * */
    void modifyUser(User user) throws SQLException;
    /**
     * 删除用户数据访问接口层
     * */
    void deleteUser(String uid) throws SQLException;
    /**
     * 分页查询用户数据访问接口层
     * */
    int FindCount() throws SQLException;

    List<User> FindUser(int currentPage, int pageSize) throws SQLException;
    /*
    * 校验用户数据访问接口
    * */
    User checkUser(String username) throws SQLException;
    /*
    * 注册用户
    * */
    void registerUser(User user) throws SQLException;

    User findUserByCode(String code) throws SQLException;
    /*
    * 更新状态码
    * */
     void updateUser(User user) throws SQLException;

    User selectUser(String username,String password) throws SQLException;

}
